package com.xin.entity.shop.dto;

import com.xin.annoations.PhoneNumber;
import com.xin.entity.crm.EmployEntity;
import com.xin.entity.shop.ShopEmployeeEntity;
import com.xin.entity.shop.ShopEntity;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotNull;

/**
 * 商户入驻dto
 */
public class ShopRegisterDto {

    @NotNull(message = "店铺信息不可以为空")
    private ShopEntity shop;

    /**
     * 文件服务器的访问地址
     */
    String serverUrl;
    /**
     * 用户携带的密钥
     */
    private String  token;

    @NotNull(message = "用户名不可以为空")
    private String username;

    @NotNull(message = "邮箱不可为空")
    @Email(message = "邮箱格式错误")
    private String email;
    @NotNull(message = "手机号不可以为空")
    @PhoneNumber
    private String phone;

    @NotNull(message = "密码不可以为空")
    private String password;

    public ShopEntity getShop() {
        return shop;
    }

    public void setShop(ShopEntity shop) {
        this.shop = shop;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    @Override
    public String toString() {
        return "ShopRegisterDto{" +
                "shop=" + shop +
                ", username='" + username + '\'' +
                ", email='" + email + '\'' +
                ", phone='" + phone + '\'' +
                ", password='" + password + '\'' +
                '}';
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public String getServerUrl() {
        return serverUrl;
    }

    public void setServerUrl(String serverUrl) {
        this.serverUrl = serverUrl;
    }
}
